package io.renren.modules.biz.tongtong.service;

import io.renren.common.page.PageData;
import io.renren.common.service.CrudService;
import io.renren.modules.biz.tongtong.dto.LockUserDTO;
import io.renren.modules.biz.tongtong.dto.TbUserDTO;
import io.renren.modules.biz.tongtong.entity.LockUserEntity;

import java.util.List;
import java.util.Map;

/**
 * 锁授权用户
 *
 * @author Mark sunlightcs@gmail.com
 * @since 1.0.0 2024-01-07
 */
public interface LockUserService extends CrudService<LockUserEntity, LockUserDTO> {

    /**
     * 分页查询
     * @param params
     * @return
     */
    PageData<LockUserDTO> page(Map<String, Object> params);

    /**
     * 用户列表
     * @param params
     * @return
     */
    List<TbUserDTO> userlist(Map<String, Object> params);

    /**
     * 根据用户id和锁id查询用户
     * @param userId
     * @param lockId
     * @return
     */
    LockUserEntity getByUserAndLock(Long userId,Long lockId);

}